package chapter04;

public class BinaryNode<E> {
    /**
     * Friendly data; accessible by other package routines
     */
    E element; //The data in the node
    /**
     * 左节点
     */
    BinaryNode<E> left;    //Left child
    /**
     * 右节点
     */
    BinaryNode<E> right;   //Right child

    public BinaryNode(E element) {
        this(element, null, null);
    }

    public BinaryNode(E element, BinaryNode left, BinaryNode right) {
        this.element = element;
        this.left = left;
        this.right = right;
    }
}
